package General;

import Database.MyTableModel;

public class Session
{
	private int id, cpt=0;
	private boolean manager;
	private String login, password, firstname, lastname;
	
	public Session(MyTableModel modelAllInfosAboutUser)
	{
		this.id = (int)(modelAllInfosAboutUser.getValueAt(0, cpt)); cpt++;
		this.login = (String)(modelAllInfosAboutUser.getValueAt(0, cpt)); cpt++;
		this.password = (String)(modelAllInfosAboutUser.getValueAt(0, cpt)); cpt++;
		this.manager = (boolean)(modelAllInfosAboutUser.getValueAt(0, cpt)); cpt++;
		this.firstname = (String)(modelAllInfosAboutUser.getValueAt(0, cpt)); cpt++;
		this.lastname = (String)(modelAllInfosAboutUser.getValueAt(0, cpt)); cpt++;
	}
	
	public int getId(){return id;}
	public boolean getManager(){return manager;}
	public String getLogin(){return login;}
	public String getPassword(){return password;}
	public String getFirstName(){return firstname;}
	public String getLastName(){return lastname;}
}
